package com.ys.homework;

/**
 * 描述: 面向对象03
 *
 * @author CodeYang
 * @version 2020/12/15 21:22
 */
public class 面向对象03 {

    public static void main(String[] args) {
        Snake snake = new Snake();
        snake.setName("蛇妖");
        snake.setLiveNum(9.0);
        snake.setAttackNum(30);
        snake.attackShow();
        snake.addHp();
        snake.move();
        System.out.println("================");
        Centipede centipede = new Centipede("蜈蚣",20,26);
        centipede.attackShow();
        centipede.move();


    }
}
